#pragma once

#include <gofcl_dac_r.h>

typedef enum {
	DAC_DO_DAC0_R = DAC_DAC0_DO_R,
	DAC_DO_DAC1_R = DAC_DAC1_DO_R,
} dac_do_re;

static inline dac_re dac_get_do_r(dac_do_re dac_do_r) {
	return (dac_re)dac_do_r;
}

static inline void dac_wreg_do(u32_s value, dac_do_re dac_no_r) {
	dac_re dac_r = dac_get_do_r(dac_no_r);
	dac_wreg(dac_r, value);
}

static inline u32_s dac_rreg_do(dac_do_re dac_no_r) {
	dac_re dac_r = dac_get_do_r(dac_no_r);
	return dac_rreg(dac_r);
}
